package com.users.rn.kit.bridge.impl.sign

import com.facebook.react.bridge.Promise
import com.facebook.react.bridge.ReactApplicationContext
import com.facebook.react.bridge.ReactMethod
import com.facebook.react.bridge.ReadableMap
import com.users.rn.kit.RNKitManager
import com.users.rn.kit.bridge.RNBasicJavaModule

/**

 * 作者：wolf on 1/11/21 11:28

 * 邮箱：bluce

 */

class SignBridge constructor(context: ReactApplicationContext) :
    RNBasicJavaModule<KitSignModule>(context) {
    override fun getBridge(): KitSignModule? {
        return RNKitManager.get(KitSignModule.RN_MODULE_NAME)
    }

    override fun getName(): String {
        return SignBridge::class.java.simpleName
    }

    @ReactMethod
    fun checkIsHaveDoctorSignAction(params: ReadableMap, promise: Promise) {
        rnBridge?.checkIsHaveDoctorSignAction(context, params, promise)
    }

    @ReactMethod
    fun jumpToBJCASignViewAction(params: ReadableMap, promise: Promise) {
        rnBridge?.jumpToBJCASignViewAction(context, params, promise)
    }

    @ReactMethod
    fun bjcasignedDataClickedSignListAction(params: ReadableMap, promise: Promise) {
        rnBridge?.bjcasignedDataClickedSignListAction(context, params, promise)
    }
}